package com.athuawei.collection;

import java.util.Collections;
import java.util.HashMap;
import java.util.Map;

public class HashMapTest {
    public static void main(String[] args) {
        Map<Integer, String> cityMap = new HashMap<>();
        cityMap.put(4, null);
        System.out.println(cityMap);
        Map<Integer, String> unmodifyMap = Collections.unmodifiableMap(cityMap);
        unmodifyMap.clear();
    }
}









